package com.huiminpay.merchant.api;

import com.huiminpay.common.cache.domain.BusinessException;
import com.huiminpay.merchant.dto.AppDTO;

import java.util.List;

public interface AppService {
    AppDTO createApp(long merchantId ,AppDTO appDTO) throws BusinessException;
    /**
     \* 查询应用是否属于某个商户
     \* @param appId
     \* @param merchantId
     \* @return
     */
    Boolean queryAppInMerchant(String appId, Long merchantId);

    AppDTO getapp(String appId);

    AppDTO queryAppByAppId(String appId);

    /**
     * 查询商户下的应用列表
     * @param merchantId
     * @return
     */
    List<AppDTO> queryAppByMerchant(Long merchantId) throws BusinessException;
    /**
     * 根据业务id查询应用
     * @param id
     * @return
     */
    AppDTO getAppById(String id) throws BusinessException;

}
